Skip to content

Indicator: create header settings if it doesn't exist - #360

Open
danirabbit wants to merge 1 commit into
mainfrom
danirabbit/indicator-notificationcreateheadersetting
Open

Indicator: create header settings if it doesn't exist#360
danirabbit wants to merge 1 commit into
mainfrom
danirabbit/indicator-notificationcreateheadersetting

Conversation

@danirabbit

Copy link
Copy Markdown
Member

When we get a new notification, make sure that we create visibility settings before trying to bind to it in items and headers

@danirabbit
danirabbit requested a review from a team September 11, 2026 16:43
@danirabbit danirabbit added this to OS 9 Sep 11, 2026
@danirabbit danirabbit moved this to Needs Review in OS 9 Sep 11, 2026
Comment thread src/Indicator.vala
// Create value if it doesn't exist and set true
var settings = new Settings ("io.elementary.panel.notifications");
var headers = (HashTable<string, bool>) settings.get_value ("headers");
if (!headers.contains (notification.desktop_id)) {

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

headers can be null here I think, so we should check for nullability ?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Needs Review

Development

Successfully merging this pull request may close these issues.

2 participants